package com.anyonavinfo.cpaddemo.view.mainview.miniradio;

import android.content.Context;

/**
 * Created by Drive on 2017/2/8.
 */

public class MiniRadioModel {
    private int band = -1;//1 radio 2 phone 3media
    private int fmFrequency = 875;
    private int amFrequency = 531;
    private int volume=15;
    private int mute=0;
    private int voiceChannel = -1;//1 radio 2 phone 3media
    private int radioStation[] = {531,531,531,875,875,875};//Position 1/2/3 4/5/6


    private MiniRadioModelHelper util;

    public MiniRadioModel(Context context) {
        util = new MiniRadioModelHelper(context);
        radioStation = util.readRadioStation();
    }
    public void saveStation(int position, int frq){
        util.saveRadioStation(position,frq);
    }

    public int[] getRadioStation() {
        return radioStation;
    }

    public void setRadioStation(int position, int frq) {
       radioStation[position-1]=frq;
    }

    public int getVolume() {
        return volume;
    }

    public void setVolume(int volume) {
        this.volume = volume;
    }

    public int getBand() {
        return band;
    }

    public void setBand(int band) {
        this.band = band;
    }

    public int getMute() {
        return mute;
    }

    public void setMute(int mute) {
        this.mute = mute;
    }

    public int getFmFrequency() {
        return fmFrequency;
    }

    public void setFmFrequency(int fmFrequency) {
        this.fmFrequency = fmFrequency;
    }

    public int getAmFrequency() {
        return amFrequency;
    }

    public void setAmFrequency(int amFrequency) {
        this.amFrequency = amFrequency;
    }

    public int getVoiceChannel() {
        return voiceChannel;
    }

    public void setVoiceChannel(int voiceChannel) {
        this.voiceChannel = voiceChannel;
    }


}
